<?php
@session_start();
$link=mysql_connect("localhost", "root", "");
if(!$link){
echo "not connected to database";
}

mysql_select_db("techworks");

$Company_name= $_POST['companyname'];
$Owner= $_POST['owner'];
$Address= $_POST['address'];
$City= $_POST['city'];
$Zip= $_POST['zip'];
$State= $_POST['state'];
$Phone= $_POST['phone'];
$Fax= $_POST['fax'];
$Email= $_POST['email'];
$Logo= $_POST['logo'];


$q= mysql_query ("insert into tw_cover_page(comp_name, own_name, address, city, zip, state, phone, fax, email, logo)
 values ('$Company_name', '$Owner', '$Address', '$City', '$Zip', '$State', '$Phone', '$Fax', '$Email', '$Logo')");

if($q){
	$_SESSION['ac']= "success";
	
	$pid = mysql_query("select * from tw_cover_page order by plan_id desc limit 1");
	$row = mysql_fetch_array($pid);
	$_SESSION['plan_id'] = $row['plan_id'];
	
	header("location: ../incubatee/wizard.php#tab_tab1 ");				
}else {
	header("location: ../incubatee/wizard.php#tab_tab1");
	
	
}

?>
